package com.example.webpractice.po;


import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.AllArgsConstructor;
import lombok.Data;

import java.util.Date;

/**
 * token表
 */
@Data
@AllArgsConstructor
@TableName("token")
public class TokenPO {
    @TableId(type = IdType.AUTO)
    private Long id;
    private Long userid;
    private String username;
    private String tablename;
    private String role;
    private String token;
    private Date expiratedtime;
    private Date addtime;

    public TokenPO(Long userid, String username, String tableName, String role, String token, Date time) {
        this.userid = userid;
        this.username = username;
        this.tablename = tableName;
        this.role = role;
        this.token = token;
        this.expiratedtime = time;
    }
}
